/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package canteen.sys.model.entity;

import java.io.Serializable;
import java.sql.Date;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

/**
 *
 * @author TNT
 */
@Entity
public class BillMaster implements Serializable {

    @Id
    @GeneratedValue
    private int bId;
    @NotNull
    private Date bDate;
    @NotNull
    private String coupenNo;
    @NotNull
    private Date coupenDate;
    @Size(min = 2, max = 50, message = "Name Category must >=2 or <=50 character")
    @Column(length = 50, nullable=false)
    private String bCategory;
    @ManyToOne
    @JoinColumn(name = "eId")
    @NotNull
    private EmployeeMaster employeeMaster;
    @NotNull
    @ManyToOne
    @JoinColumn(name = "lId")
    private LoginMaster loginMaster;
    @NotNull
    private int status;
    @ManyToOne
    @JoinColumn(name = "deptId")
    private DepartmentMaster department;

    public BillMaster(int bId, Date bDate, String coupenNo, Date coupenDate, String bCategory, EmployeeMaster employeeMaster, DepartmentMaster departmentMaster, LoginMaster loginMaster, int status) {
        this.bId = bId;
        this.bDate = bDate;
        this.coupenNo = coupenNo;
        this.coupenDate = coupenDate;
        this.bCategory = bCategory;
        this.employeeMaster = employeeMaster;
        this.department = departmentMaster;
        this.loginMaster = loginMaster;
        this.status = status;
    }

    public BillMaster() {
    }

    public LoginMaster getLoginMaster() {
        return loginMaster;
    }

    public void setLoginMaster(LoginMaster loginMaster) {
        this.loginMaster = loginMaster;
    }

    public EmployeeMaster getEmployeeMaster() {
        return employeeMaster;
    }

    public void setEmployeeMaster(EmployeeMaster employeeMaster) {
        this.employeeMaster = employeeMaster;
    }

    public DepartmentMaster getDepartment() {
        return department;
    }

    public void setDepartment(DepartmentMaster department) {
        this.department = department;
    }

    public int getbId() {
        return bId;
    }

    public void setbId(int bId) {
        this.bId = bId;
    }

    public Date getbDate() {
        return bDate;
    }

    public void setbDate(Date bDate) {
        this.bDate = bDate;
    }

    public String getCoupenNo() {
        return coupenNo;
    }

    public void setCoupenNo(String coupenNo) {
        this.coupenNo = coupenNo;
    }

    public Date getCoupenDate() {
        return coupenDate;
    }

    public void setCoupenDate(Date coupenDate) {
        this.coupenDate = coupenDate;
    }

    public String getbCategory() {
        return bCategory;
    }

    public void setbCategory(String bCategory) {
        this.bCategory = bCategory;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }
}
